import java.io.File;

public class Tes2 {
    public static void main(String[] args) {
        System.out.println("文件如下");

        File file =new File("D:/03chenhaisheng");

        File files []=file.listFiles();

        for (File file2 :
                files) {
            System.out.println("|-"+file2.getName());
        }
    }
}
